/**
 * <b>项目名：</b>hclv-web<br/>  
 * <b>包名：</b>com.flea.hclv.controller<br/>  
 * <b>文件名：</b>HAddressController.java<br/>  
 * <b>版本信息：</b>1.0<br/>  
 * <b>日期：</b>2018年9月16日 上午4:15:57<br/>  
 * <b>COPYRIGHT 2010-2012 ALL RIGHTS RESERVED 虫子科技</b>-版权所有<br/>
 */
package com.flea.hclv.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.flea.hclv.model.entity.HAddress;
import com.flea.hclv.service.HAddressService;
import com.flea.system.utils.ControllerResult;

/**
 * @description
 * @createTime 2018年9月16日 上午4:15:57
 * @modifyTime 
 * @author myflea@163.com
 * @version 1.0
 */
@Controller
@RequestMapping("/flea/hclv/address")
public class HAddressController {
	@Autowired
	private HAddressService addressService;
	@RequestMapping("/findById")
	public void queryById(HttpServletRequest request,
			HttpServletResponse response) {
		String addressId = request.getParameter("addressId");
		HAddress result = addressService.findById(addressId);
		ControllerResult conresult = new ControllerResult(true, "操作成功", result);
		conresult.WriteToPage(response);


	}
	@RequestMapping("/findByHotelId")
	public void findByHotelId(HttpServletRequest request,
			HttpServletResponse response) {
		String hotelId = request.getParameter("hotelId");
		HAddress result = addressService.findByHotelId(hotelId);
		ControllerResult conresult = new ControllerResult(true, "操作成功", result);
		conresult.WriteToPage(response);
		
		
	}
	@RequestMapping("/findByReUUid")
	public void findByReUUid(HttpServletRequest request,
			HttpServletResponse response) {
		String uuid = request.getParameter("uuid");
		HAddress result = addressService.findByHotelId(uuid);
		ControllerResult conresult = new ControllerResult(true, "操作成功", result);
		conresult.WriteToPage(response);
		
		
	}
}
